package Data::Conveyor::YAML::Active::MakeWholeTicketBlock;

# $Id: MakeWholeTicketBlock.pm 13653 2007-10-22 09:11:20Z gr $

use warnings;
use strict;
use YAML::Active qw/assert_hashref hash_activate/;


our $VERSION = '0.02';


use base 'Class::Scaffold::YAML::Active';


sub yaml_activate {
    my ($self, $phase) = @_;
    assert_hashref($self);
    my $hash = hash_activate($self, $phase);

    my %args = %$hash;
    delete @args{ qw/ticket_no prefix suffix/ };

    {
        ticket_no => $hash->{ticket_no} ||
            $self->delegate->make_obj('test_ticket')->gen_temp_ticket_no(
                prefix => $hash->{prefix},
                suffix => $hash->{suffix},
            ),
        %args,
    }
}


1;


__END__

{% USE p = PodGenerated %}

=head1 NAME

{% p.package %} - stage-based conveyor-belt-like ticket handling system

=head1 SYNOPSIS

    {% p.package %}->new;

=head1 DESCRIPTION

None yet. This is an early release; fully functional, but undocumented. The
next release will have more documentation.

=head1 METHODS

=over 4

{% p.write_methods %}

=back

{% p.write_inheritance %}

{% PROCESS standard_pod %}

=cut

